﻿using Commonality;
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Security.Principal;
using System.Text;
using System.Threading.Tasks;
using System.Xml.Linq;
using static Commonality.Client;
using static Commonality.Enum.Financing.Handle;
using static Commonality.Examineandapprove;

namespace Models
{
    /// <summary>
    /// 客户租赁业务表
    /// </summary>
    [Table("CarLeaseProject")]
    public class CarLeaseProject: AuditFiled<int>
    {
        /// <summary>
        /// 渠道外键
        /// </summary>
        public string? ChannelId { get; set; }
        /// <summary>
        /// 品牌外键
        /// </summary>
        public int BrandId { get; set; }
        /// <summary>
        /// 系列外键
        /// </summary>
        public int SeriesID { get; set; }
        /// <summary>
        /// 型号外键
        /// </summary>
        public int VersionID { get; set; }
        /// <summary>
        /// 汽车颜色
        /// </summary>
        public string? Color { get; set; }
        /// <summary>
        /// 官方指导价
        /// </summary>
        public decimal PuidePrice { get; set; }
        /// <summary>
        /// 具体配置
        /// </summary>
        public string? SpecificConfiguration { get; set; }
        /// <summary>
        /// 备注
        /// </summary>
        public string? Remark { get; set; }
        /// <summary>
        /// 租赁类型
        /// </summary>
        public string? LeaseCategory { get; set; }
        /// <summary>
        /// 租赁数量
        /// </summary>
        public int leaseNum { get; set; }
        /// <summary>
        ///省Id;地区表外省外键
        /// </summary>
        [Display(Name = "省Id;地区表外省外键")]
        [Column(TypeName = "int")]
        [Editable(true)]
        public int ProvinceId { get; set; }

        /// <summary>
        ///市Id;地区表外市外键
        /// </summary>
        [Display(Name = "市Id;地区表外市外键")]
        [Column(TypeName = "int")]
        [Editable(true)]
        public int CityId { get; set; }

        /// <summary>
        /// 项目归属
        /// </summary>
        public string? Ownership { get; set; }
        /// <summary>
        /// 业务状态
        /// </summary>
        public Examine Checked { get; set; }
        /// <summary>
        /// 立项时间
        /// </summary>
        public DateTime Projectinitiationtime { get; set; }= DateTime.Now;
        /// <summary>
        /// 业务经办
        /// </summary>
        public Sell Businesshandling { get; set; }
        /// <summary>
        /// 客户类型
        /// </summary>
        public Cltype Customer { get; set; }
        /// <summary>
        /// 驾龄情况
        /// </summary>
        public string? Drivingexperience { get; set; }
        /// <summary>
        /// 当地居住时间
        /// </summary>
        public string? Localresidence { get; set; }
        /// <summary>
        /// 当地驾龄情况
        /// </summary>
        public string? Localdriving { get; set; }
        /// <summary>
        /// 客户名称
        /// </summary>
        public string? Name { get; set; }
        /// <summary>
        /// 立项日期
        /// </summary>
        public DateTime? ProjectApprovalDate { get; set; }
        /// <summary>
        /// 联系电话
        /// </summary>
        public string? UserPhone { get; set; }
        /// <summary>
        /// 性别
        /// </summary>
        public string? Sex { get; set; }
        /// <summary>
        /// 身份证号
        /// </summary>
        public string? IDCard { get; set; }
        /// <summary>
        /// 婚姻状况
        /// </summary>
        public string? MaritalStatus { get; set; }
        /// <summary>
        /// 既往工作单位
        /// </summary>
        public string? PreviousEmployer { get; set; }
        /// <summary>
        /// 工作时间
        /// </summary>
        public DateTime? WorkTime { get; set; }
        /// <summary>
        /// 部门
        /// </summary>
        public string? Department { get; set; }
        /// <summary>
        /// 职位
        /// </summary>
        public string? Position { get; set; }
        /// <summary>
        /// 现居住地
        /// </summary>
        public string? CurrentAddress { get; set; }
        /// <summary>
        /// 驾龄情况
        /// </summary>
        public string? DrivingYears { get; set; }
        /// <summary>
        /// 当地居住时间
        /// </summary>
        public string? CurrentDwellTime { get; set; }
        /// <summary>
        /// 当地驾龄情况
        /// </summary>
        public string? CurrentDrivingYears { get; set; }

        [Display(Name = "配偶姓名")]
        [Column(TypeName = "Nvarchar(40)")]
        [Editable(true)]
        /// <summary>
        /// 配偶姓名
        /// </summary>
        public string? MateName { get; set; }
        [Display(Name = "配偶联系电话")]
        [Column(TypeName = "Nvarchar(11)")]
        [Editable(true)]
        /// <summary>
        /// 配偶联系电话
        /// </summary>
        public string? Re_Phone { get; set; }
        [Display(Name = "配偶身份证号")]
        [Column(TypeName = "Nvarchar(18)")]
        [Editable(true)]
        /// <summary>
        /// 配偶身份证号
        /// </summary>
        public string? UserLeaseID { get; set; }
        [Display(Name = "配偶月收入")]
        [Column(TypeName = "decimal(18,2)")]
        [Editable(true)]
        /// <summary>
        /// 配偶月收入
        /// </summary>
        public decimal? Monthlyincome { get; set; }
        [Display(Name = "配偶工作单位")]
        [Column(TypeName = "Nvarchar(40)")]
        [Editable(true)]
        /// <summary>
        /// 配偶工作单位
        /// </summary>
        public string? Professional { get; set; }
        [Display(Name = "配偶担保")]
        [Column(TypeName = "Nvarchar(2)")]
        [Editable(true)]
        /// <summary>
        /// 配偶担保
        /// </summary>
        public string? Whetherornot { get; set; }
        [Display(Name = "配偶工作职务")]
        [Column(TypeName = "Nvarchar(40)")]
        [Editable(true)]
        /// <summary>
        /// 配偶工作职务
        /// </summary>
        public string? job { get; set; }
        [Display(Name = "子女情况")]
        [Column(TypeName = "Nvarchar(40)")]
        [Editable(true)]
        /// <summary>
        /// 子女情况
        /// </summary>
        public string? Situation { get; set; }
        [Display(Name = "家庭其他收入(元)")]
        [Column(TypeName = "decimal(18,2)")]
        [Editable(true)]
        /// <summary>
        /// 家庭其他收入(元)
        /// </summary>
        public decimal? Income { get; set; }
        [Display(Name = "房屋类型")]
        [Column(TypeName = "Nvarchar(40)")]
        [Editable(true)]
        /// <summary>
        /// 房屋类型
        /// </summary>
        public string? Tenement { get; set; }
        [Display(Name = "其他描述")]
        [Column(TypeName = "Nvarchar(200)")]
        [Editable(true)]
        /// <summary>
        /// 其他描述
        /// </summary>
        public string? Other { get; set; }
        [Display(Name = "契约编号")]
        [Column(TypeName = "Nvarchar(40)")]
        [Editable(true)]
        /// <summary>
        /// 契约编号
        /// </summary>
        public string? ContractNo { get; set; }

    }
}
